package cn.ahaiahaixx.entity;

import com.github.pagehelper.Page;

/**
 * -分页信息
 * 
 * @author Aiden Pearce
 *
 */
public class PageBean extends BaseEntity {

	private static final long serialVersionUID = -3948585182230615792L;

	private int pageSize = 10;

	private int pageNumber = -1;

	private int pageCount = 0;

	private long totai = 0;

	public PageBean() {

	}

	/**
	 * 设置分页信息
	 * @param page
	 */
	public void setPageInfo(Page<?> page) {
		pageCount = page.getPages();
		pageNumber = page.getPageNum();
		pageSize = page.getPageSize();
		totai = page.getTotal();
	}

	public int getPageSize() {
		return pageSize;
	}

	public void setPageSize(int pageSize) {
		this.pageSize = pageSize;
	}

	public int getPageNumber() {
		return pageNumber;
	}

	public void setPageNumber(int pageNumber) {
		this.pageNumber = pageNumber;
	}

	public int getPageCount() {
		return pageCount;
	}

	public void setPageCount(int pageCount) {
		this.pageCount = pageCount;
	}

	public long getTotai() {
		return totai;
	}

	public void setTotai(long totai) {
		this.totai = totai;
	}

}
